﻿<%@ Page Language="C#" MasterPageFile="~/Pages/MasterPage.master" AutoEventWireup="true"
    CodeFile="Cart.aspx.cs" Inherits="Pages_Cart" Title="Giỏ Hàng" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="Server">
    <style type="text/css">
        .style3
        {
            width: 550px;
        }
        .style4
        {
            
            width: 550px;
        }
        .style5
        {
            width: 260px;
        }
        .style6
        {
            height: 30px;
            width: 160px;
        }
        .style7
        {
            width: 160px;
        }
        .style8
        {
            width: 227px;
        }
    </style>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="Server">
 <div class="san_pham_menu_top">
            <p>
                Giỏ Hàng </p>
        </div>
    <table  cellpadding="0" cellspacing="0" width="100%">
        <tr>
            <td align="left" valign="middle" class="style3">
                &nbsp;&nbsp;
                <table align="left" style="border: 1px solid #cccccc;" cellpadding="0" cellspacing="0">
                    <tr>
                        <td width="70px" align="center" style="border-right: 1px solid #cccccc; background-color: #666666;">
                            <span class="style_text_Cart">Xoá</span>
                        </td>
                        <td align="center" style="border-right: 1px solid #cccccc; background-color: #666666;
                            " class="style6">
                            <span class="style_text_Cart">Hình ảnh</span>
                        </td>
                        <td align="center" style="border-right: 1px solid #cccccc; background-color: #666666;">
                            <span class="style_text_Cart">Tên Sản Phẩm</span>
                        </td>
                        <td align="center" width="90" style="border-right: 1px solid #cccccc; background-color: #666666;">
                            <span class="style_text_Cart">Số lượng</span>
                        </td>
                        <td align="center" 
                            style="border-right: 1px solid #cccccc; background-color: #666666;" 
                            class="style8">
                            <span class="style_text_Cart">Đơn giá</span>
                        </td>
                        <td align="center" 
                            style="border-right: 0px solid #cccccc; background-color: #666666;" 
                            class="style5">
                            <span class="style_text_Cart">Thành tiền</span>
                        </td>
                    </tr>
                    <asp:Repeater ID="mylist" runat="server">
                        <ItemTemplate>
                            <tr>
                                <td align="center" style="border-right: 1px solid #cccccc; border-bottom: 1px solid #cccccc;">
                                    <asp:CheckBox ID="Remove" runat="server" />
                                </td>
                                <td align="center" style="border-right: 1px solid #cccccc; border-bottom: 1px solid #cccccc;">
                                    <asp:HiddenField ID="id" Value='<%#DataBinder.Eval(Container.DataItem,"idPro")%>'
                                        runat="server" />
                                    <%--<asp:Label ID="id" runat="server" Text='<%#DataBinder.Eval(Container.DataItem,"IdPro")%>'
                                           Visible="false"></asp:Label>--%>
                                    <asp:Image ID="Image1" runat="server" Height="86px" ImageUrl='<%# Eval("imagePro") %>'
                                        Width="85px" />
                                </td>
                                <td align="center" style="width: 200px; border-right: 1px solid #cccccc; border-bottom: 1px solid #cccccc;">
                                    <span class="style_text_cart_product_name">
                                        <%#DataBinder.Eval(Container.DataItem, "namePro")%></span>
                                </td>
                                <td align="center" style="border-right: 1px solid #cccccc; border-bottom: 1px solid #cccccc;
                                    border-bottom: 1px solid #cccccc;">
                                    <asp:TextBox ID="Soluong" runat="server" Text='<%#DataBinder.Eval(Container.DataItem,"luongPro") %>'
                                        Width="30px"></asp:TextBox>
                                    <%--<cc1:FilteredTextBoxExtender ID="FilteredTextBoxExtender1" runat="server" TargetControlID="Soluong"
                                                FilterType="Custom, Numbers" ValidChars=".">
                                            </cc1:FilteredTextBoxExtender>--%>
                                </td>
                                <td align="center" style="border-right: 1px solid #cccccc; border-bottom: 1px solid #cccccc;">
                                    <span class="style_text_cart_product_price">
                                        <%#string.Format("{0:#,##0}", (int)DataBinder.Eval(Container.DataItem, "pricePro"))%>
                                        VNĐ</span>
                                </td>
                                <td align="center" style="border-right: 0px solid #cccccc; border-bottom: 1px solid #cccccc;">
                                    <span class="style_text_Price_total">
                                        <%#string.Format("{0:#,##0}", ((int)DataBinder.Eval(Container.DataItem, "LuongPro")) * ((int)DataBinder.Eval(Container.DataItem, "PricePro")))%>&nbsp;VNĐ</span>
                                </td>
                            </tr>
                        </ItemTemplate>
                    </asp:Repeater>
                    <tr style="border: 1px solid #cccccc;">
                        <td colspan="7" align="right" class="style_text_Price_total">
                            <br />
                            <span class="style_text1">Tổng GT thanh toán :&nbsp;&nbsp;</span>
                            <asp:Label ID="totalPrice" runat="server" Font-Bold="True" ForeColor="Red"></asp:Label>
                            VNĐ
                        </td>
                        <%--<td width="90" align="center">
                                <span class="style_text_cart_product_name">
                                <asp:Label ID="totalPrice" runat="server" Text=""></asp:Label>
                                VNĐ</span>
                            </td>--%>
                    </tr>
                </table>
                <br />
            </td>
        </tr>
        <tr>
            <td align="center" class="style4">
                <table width="100%">
                    <tr>
                        <td align="left" valign="bottom">
                            <asp:Button ID="btnUpdate" runat="server" Text="Cập nhật" CssClass="sytle_button"
                                ValidationGroup="checkVadidate" OnClick="btnUpdate_Click" Font-Bold="True" 
                                ForeColor="White" />
                        </td>
                        <td align="center" valign="bottom">
                            <asp:Button ID="btnBuy" runat="server" CssClass="sytle_button" Text="Tiếp tục mua hàng"
                                ValidationGroup="checkVadidate" OnClick="btnBuy_Click" Font-Bold="True" 
                                ForeColor="White" />
                        </td>
                        <td align="right" valign="bottom">
                            <asp:Button ID="btnThanhtoan" CssClass="sytle_button" runat="server" Text="Thanh toán"
                                ValidationGroup="checkVadidate" OnClick="btnThanhtoan_Click" 
                                Font-Bold="True" ForeColor="White" />
                        </td>
                    </tr>
                </table>
            </td>
        </tr>
    </table>
</asp:Content>
